package com.yonyou.cyxdms.basedata.service.dto.vehiclemodel;

import javax.validation.constraints.NotNull;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.yonyou.cyx.function.utils.jsonserializer.localdatetime.JsonLocalDateTimeDeserializer;
import com.yonyou.cyx.function.utils.jsonserializer.localdatetime.JsonLocalDateTimeQueryBeginDeserializer;
import com.yonyou.cyx.function.utils.jsonserializer.localdatetime.JsonLocalDateTimeQueryBeginSerializer;
import com.yonyou.cyx.function.utils.jsonserializer.localdatetime.JsonLocalDateTimeSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.time.LocalDateTime;

/**
 * 选装 - 新增/编辑DTO
 *
 * @author zhangys
 * @since 2020-2-24
 */
@ApiModel(value = "OptionModifyDTO", description = "选装 - 新增/编辑DTO")
public class OptionModifyDTO {
	
	@ApiModelProperty(value = "选装主键ID-编辑时必传，新增传递null")
    private Long optionId;

	@ApiModelProperty(value = "品牌ID-品牌名称下拉框传递品牌ID")
    @NotNull(message = "品牌名称不能为空")
    private Long brandId;

    @ApiModelProperty(value = "车系ID-车系名称下拉框传递车系ID")
    @NotNull(message = "车系名称不能为空")
    private Long seriesId;

    @ApiModelProperty(value = "车型ID-车型名称下拉框传递车型ID")
    @NotNull(message = "车型名称不能为空")
    private Long modelId;
    
    @ApiModelProperty(value = "配置ID-车型名称下拉框传递配置ID")
    @NotNull(message = "配置名称不能为空")
    private Long packageId;
    
    @ApiModelProperty(value = "选装代码")
    @NotNull(message = "选装代码不能为空")
    private String optionCode;

    @ApiModelProperty(value = "选装名称")
    @NotNull(message = "选装名称不能为空")
    private String optionName;
    
    @ApiModelProperty(value = "数据来源")
    private Integer dataSources;

    @ApiModelProperty(value = "是否启用")
    private Integer isValid;
    
    @ApiModelProperty(value = "版本号-编辑时必传")
    private Integer recordVersion;

	@ApiModelProperty(value = "启用时间")
	@JsonDeserialize(using = JsonLocalDateTimeQueryBeginDeserializer.class)
	@JsonSerialize(using = JsonLocalDateTimeQueryBeginSerializer.class)
	private LocalDateTime startDate;

	@ApiModelProperty(value = "启用标识")
	private Integer startType;


	public Long getOptionId() {
		return optionId;
	}

	public void setOptionId(Long optionId) {
		this.optionId = optionId;
	}

	public Long getBrandId() {
		return brandId;
	}

	public void setBrandId(Long brandId) {
		this.brandId = brandId;
	}

	public Long getSeriesId() {
		return seriesId;
	}

	public void setSeriesId(Long seriesId) {
		this.seriesId = seriesId;
	}

	public Long getModelId() {
		return modelId;
	}

	public void setModelId(Long modelId) {
		this.modelId = modelId;
	}

	public Long getPackageId() {
		return packageId;
	}

	public void setPackageId(Long packageId) {
		this.packageId = packageId;
	}

	public String getOptionCode() {
		return optionCode;
	}

	public void setOptionCode(String optionCode) {
		this.optionCode = optionCode;
	}

	public String getOptionName() {
		return optionName;
	}

	public void setOptionName(String optionName) {
		this.optionName = optionName;
	}

	public Integer getRecordVersion() {
		return recordVersion;
	}

	public void setRecordVersion(Integer recordVersion) {
		this.recordVersion = recordVersion;
	}
	public Integer getDataSources() {
		return dataSources;
	}

	public void setDataSources(Integer dataSources) {
		this.dataSources = dataSources;
	}

	public Integer getIsValid() {
		return isValid;
	}

	public void setIsValid(Integer isValid) {
		this.isValid = isValid;
	}

	public LocalDateTime getStartDate() {
		return startDate;
	}

	public void setStartDate(LocalDateTime startDate) {
		this.startDate = startDate;
	}

	public Integer getStartType() {
		return startType;
	}

	public void setStartType(Integer startType) {
		this.startType = startType;
	}

	@Override
	public String toString() {
		return "OptionModifyDTO [optionId=" + optionId + ", brandId=" + brandId + ", seriesId=" + seriesId
				+ ", modelId=" + modelId + ", packageId=" + packageId + ", optionCode=" + optionCode + ", optionName="
				+ optionName + ", dataSources=" + dataSources + ", isValid=" + isValid + ", recordVersion="
				+ recordVersion + ", startType=" + startType + ", startDate=" + startDate + "]";
	}

    
}
